#!/bin/bash
rm -rf ai-web-admin.zip
#pnpm build
#cd dist
zip ai-web-admin.zip -r . -x "node_modules/*"
ssh gptuser@47.106.247.46 "mkdir -p /mnt/gpt/ai-web-admin/ && rm -rf /mnt/gpt/ai-web-admin/*"
scp ai-web-admin.zip gptuser@47.106.247.46:/mnt/gpt/ai-web-admin/
rm -rf ai-web-admin.zip
scp autoDeploy.sh gptuser@47.106.247.46:/mnt/gpt/ai-web-admin/
ssh gptuser@47.106.247.46 "cd /mnt/gpt/ai-web-admin/ && chmod -R a+x * && sh autoDeploy.sh"
